var path = require('path');
//console.log('process.env.NODE_ENV=' + process.env.NODE_ENV)
var WebpackDevServer = require("webpack-dev-server");
module.exports = {

    baseUrl: process.env.NODE_ENV === 'production' ? '/yfs/' : '/',
    devServer: {
        port: 8066, // 端口号
        host: '0.0.0.0',
        https: false, // https:{type:Boolean}
        open: false,//配置自动启动浏览器
        proxy: {
            '/Chat': {
             //target: 'http://210.51.168.204:8089/',//测试网
             target:'https://comment.96189.com/',//现网
                ws: true,
                changeOrigin: true,
                // secure: false
            }
        }
    },
    configureWebpack: config => {
       // console.log('process.env.NODE_ENV=' + process.env.NODE_ENV)
        if (process.env.NODE_ENV === 'development') {
            config.devtool = 'source-map';
        }

    }

};